-
-
Notifications
You must be signed in to change notification settings - Fork 5.2k
[Workflow] Update workflow.rst #18058
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
workflow.rst
Outdated
@@ -160,6 +160,10 @@ follows: | |||
If you are creating your first workflows, consider using the ``workflow:dump`` | |||
command to :doc:`debug the workflow contents </workflow/dumping-workflows>`. | |||
|
|||
.. tip:: | |||
|
|||
Since Symfony 3.2, you can use constants in YAML files and add some in the BlogPost entity for places ``draft`` by ``!php/const App\Entity\BlogPost::STATE_DRAFT`` or for transitions ``to_review`` by ``!php/const App\Entity\BlogPost::TRANSITION_TO_REVIEW``. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't know if it's relevant to indicate that it's since Symfony 3.2, are we used to refer to old versions?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm not sure too... I start my update with this article : https://symfony.com/blog/new-in-symfony-3-2-php-constants-in-yaml-files
I just discover than we can add constant in YAML, since 2016 :(
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes there's no ned to add the reference to Symfony 3.2. So, let's remove "Since Symfony 3.2, " and keep the rest. Thanks.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done, thank you !
I like this use case, maybe this is also an opportunity to add it on this page which is about yaml format https://symfony.com/doc/current/reference/formats/yaml.html ? |
Michaël, thanks a lot for improving docs ... and congrats on your first Symfony Docs contribution 🎉 |
Add Tip for using constants in YAML files to define a large workflow and use these constants everywhere ! :) Cheers to the team <3